<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<!DOCTYPE html>
<html>
<head>
    <title></title>
    <meta charset="UTF-8">
    <link rel="stylesheet" type="text/css" href="${pageContext.request.contextPath}/css/bootstrap.css" />
    <link rel="stylesheet" type="text/css" href="${pageContext.request.contextPath}/css/bootstrap-responsive.css" />
    <link rel="stylesheet" type="text/css" href="${pageContext.request.contextPath}/css/style.css" />
    <script type="text/javascript" src="${pageContext.request.contextPath}/js/jquery.js"></script>
    <script type="text/javascript" src="${pageContext.request.contextPath}/js/bootstrap.js"></script>
    <script type="text/javascript" src="${pageContext.request.contextPath}/js/ckform.js"></script>
    <script type="text/javascript" src="${pageContext.request.contextPath}/js/common.js"></script>

 

    <style type="text/css">
        body {
            padding-bottom: 40px;
            font-size: 12px;
        }
        .sidebar-nav {
            padding: 9px 0;
        }

        @media (max-width: 980px) {
            /* Enable use of floated navbar text */
            .navbar-text.pull-right {
                float: none;
                padding-left: 5px;
                padding-right: 5px;
            }
        }
		.inputStyle {
		  vertical-align: text-bottom;
		  margin-bottom: 2px;
		  *margin-bottom: -2px;  /* 兼容IE6，IE7 */
		}
    </style>
</head>
<body>
<form action="${pageContext.request.contextPath}/user/updateUser.do" method="post" class="definewidth m20">
	<input type="hidden" name="userID" value="${userInfo.userID }" />
	<input type="hidden" name="checkInTime" value="${userInfo.checkInTime}" />
    <table class="table table-bordered table-hover definewidth m10">
        <tr>
            <td width="10%" class="tableleft">姓名</td>
            <td><input type="text" name="userName" value="${userInfo.userName }"/></td>
        </tr>
        <tr>
            <td class="tableleft">电话</td>
            <td><input type="text" name="phone" value="${userInfo.phone }"/></td>
        </tr>
        <tr>
            <td class="tableleft">性别</td>
            <td>
            	<input type="radio" class="inputStyle" name="sex" ${userInfo.sex==0?"checked='checked'":"" } value="0"/>男
            	 &nbsp;&nbsp;
            	<input type="radio" class="inputStyle" name="sex" ${userInfo.sex==1?"checked='checked'":"" } value="1"/>女
            </td>
        </tr>
        <tr>
           <td class="tableleft">是否激活</td>
            <td>
            	<input type="radio" class="inputStyle" name="isDelete" ${userInfo.isDelete==0?"checked='checked'":"" } value="0"/>是
            	 &nbsp;&nbsp;
            	<input type="radio" class="inputStyle" name="isDelete" ${userInfo.isDelete==1?"checked='checked'":"" } value="1"/>否
            </td>
        </tr>
        <tr>
           <td class="tableleft">账号</td>
            <td><input type="text" name="account" value="${userInfo.account }"/></td>
        </tr>
        <tr>
            <td class="tableleft">角色</td>
            <td>
                <select name="roleInfo.roleID">
                	<option value="-1">--请选择--</option>
                	<c:forEach items="${roleInfos}" var="roleInfo">
                		<option value="${roleInfo.roleID }" ${userInfo.roleInfo.roleID==roleInfo.roleID?"selected='selected'":"" }>${roleInfo.roleName }</option>
                	</c:forEach>
                </select>
            </td>
        </tr>
        <tr>
           <td class="tableleft">重置密码</td>
            <td>
            	<input type="hidden" name="password" value="${userInfo.password}"/>
            	<input type="radio" class="inputStyle" name="resetPassword" value="0"/>是
            	 &nbsp;&nbsp;
            	<input type="radio" class="inputStyle" name="resetPassword" checked="checked" value="1"/>否
            </td>
        </tr>
        <tr>
            <td class="tableleft">邮箱</td>
            <td><input type="text" name="email" value="${userInfo.email }"/></td>
        </tr>
        <tr>
            <td class="tableleft"></td>
            <td>
                <button type="submit" class="btn btn-primary">保存</button>				 &nbsp;&nbsp;<button type="button" onclick="history.go(-1);" class="btn btn-success" name="backid" id="backid">返回列表</button>
            </td>
        </tr>
    </table>
</form>
</body>
</html>